﻿using System;
using System.Collections.Generic;

namespace Model
{
     ///<summary>
     ///实体类SYSTEM_ROLE_RIGHT
     ///</summary>
     public class SYSTEM_ROLE_RIGHT
     {
         private int __id=0 ;
         private string __role=string.Empty ;
         private string __rights=string.Empty ;

         private Dictionary<string, bool> __Changed = new Dictionary<string, bool>();


         public SYSTEM_ROLE_RIGHT()
         {
             this.__Changed.Add("id",false);
             this.__Changed.Add("role",false);
             this.__Changed.Add("rights",false);
         }

         /// <summary>
         /// 将类重置到初始化状态
         /// </summary>
         public void Reset()
         {
             this.__id =0;
             this.__role =string.Empty;
             this.__rights =string.Empty;
             this.__Changed["id"] = false;
             this.__Changed["role"] = false;
             this.__Changed["rights"] = false;
         }

         /// <summary>
         /// 获取类中成员的改变状态
         /// </summary>
         public bool Changed(string strKey)
         {
             return __Changed[strKey];
         }

         /// <summary>
         ///设置或获取类中的[id]的数据
         /// </summary>
         public int id
         {
              set{ __id = value; __Changed["id"] = true;}
              get{return __id;}
         }
         /// <summary>
         ///设置或获取类中的[role]的数据
         /// </summary>
         public string role
         {
              set{ __role = value.Replace("'","’"); __Changed["role"] = true;}
              get{return __role;}
         }
         /// <summary>
         ///设置或获取类中的[rights]的数据
         /// </summary>
         public string rights
         {
              set{ __rights = value.Replace("'","’"); __Changed["rights"] = true;}
              get{return __rights;}
         }
    }
}
